$OpenBSD: patch-ksmserver_CMakeLists_txt,v 1.2 2014/01/28 14:49:26 zhuk Exp $
Fix build.
--- ksmserver/CMakeLists.txt.orig	Sat Oct  5 02:09:06 2013
+++ ksmserver/CMakeLists.txt	Sat Oct  5 02:12:06 2013
@@ -17,7 +17,9 @@ if(NOT WIN32)
    set(SCREEN_LOCKER "screenlocker_static")
 endif(NOT WIN32)
 
-check_library_exists(ICE _IceTransNoListen "" HAVE__ICETRANSNOLISTEN)
+if(X11_ICE_FOUND)
+  check_library_exists(${X11_ICE_LIB} _IceTransNoListen "" HAVE__ICETRANSNOLISTEN)
+endif(X11_ICE_FOUND)
 configure_file(config-ksmserver.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config-ksmserver.h)
 
 ########### next target ###############
